-
-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cycle wallpaper and theme #2
base: master
Are you sure you want to change the base?
Conversation
Add script to cycle through and set wallpaper and themes for desktop and login screen
The whole file was remade. Original output and use stays the same.
Thank you for using snake_case! I need to rework some scripts to follow this convention. Will test it later. Looks like you hardcode some paths. |
#!/usr/bin/env sh | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use bash in your shebang if the script is not POSIX (sh) at all, so the linters won't scream.
#!/usr/bin/env sh | |
#!/usr/bin/env bash | |
WALL_SCRIPT="$HOME/.local/share/bin/swwwallpaper.sh" | ||
THEME_SCRIPT="$HOME/.local/share/bin/themeswitch.sh" | ||
#SDDM_SCRIPT="$HOME/bin/setsddmwallpaper" | ||
SDDM_SCRIPT="$HOME/.local/share/bin/setsddmwallpaper.sh" | ||
LOG_FILE="$HOME/.local/share/cyclewallpaperandtheme.log" | ||
WALL_CYCLE_FILE="$HOME/.local/share/cyclewallpapercount" | ||
THEME_CYCLE_FILE="$HOME/.local/share/cyclethemecount" | ||
THEME_CHANGE_FLAG_FILE="$HOME/.local/share/cyclethemeflag" | ||
THEMES_DIR="$HOME/.config/hyde/themes" | ||
HYDE_CONFIG="$HOME/.config/hyde/hyde.conf" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Too hardcoded, I will expose a global variables later and will use it so global stuff can be source/imported. Also don't put logs in .local/share.
Add the path to the script itself and source the global control to update the variable paths
@kRHYME7, I made changes based on your comments. What do you think? |
Can you switch to |
@Davi-S Please resolve reviews. I won't merge the sddm script as this is not a good approach, you can remove it for now so we can move forward |
# Configuration | ||
SDDM_THEME_CONFIG="/usr/share/sddm/themes/Corners/theme.conf" | ||
BACKGROUND_DIR="/usr/share/sddm/themes/Corners/backgrounds" | ||
WALLPAPER_NAME="customwallpaper" | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
HyDE does have Candy theme too. how to handle it. This is the reason why there's 2 sddm wallpaper setter script in the PR. Both don't handle the other theme. Also this is the reason @prasanth remove the script. We should rethink how to properly do it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would it be better to make the "cyclewallpaperandtheme.sh" have a display manager script as parameter?
This way the user can create/edit the scripts as he likes to make them work for any theme or display manager he uses. AKA: Dependency Injection to achieve Inversion of Control
The cyclewallpaperandtheme.sh script now can receive a display-manager-wallpaper-script as argument instead of relying on a predefined script. The display manager scripts must have the wallpaper path as argument. It will be passed by the cyclewallpaperandtheme.sh script
…/HyDE-yerak-fork into cicle-wallpaper-and-theme
Pull Request
Description
This pull aims to append two new scripts that can cycle through all installed wallpapers and themes and set them for the desktop and SDDM Corners theme. This is useful for those who want to see all wallpapers and themes they have installed or just is undecided on which one to use; for the latter, the user can set a cronjob to run the script periodically, thus having a new look on its PC from time to time.
(SDDM wallpaper will match the one on the desktop)
Type of change
Checklist